@extends('layouts.auth')

@section('title', '修改密码')

@section('content')
<div class="P-UserCenter mt-2">
    <div class="container">
        <div class="row d-none d-md-block bg-white mb-2">
        @include('auth.partials.subnav')
        </div>

        <div class="row bg-white">
            <div class="border-bottom mt-4"><h4 class="fs-5 py-2">{{ $title }}</h4></div>
            <form class="ChangeForm mx-auto py-5" style="max-width: 25rem;" method="post" enctype="multipart/form-data" action="../doaction.php">
                <div class="form-group">
                    <label for="name" class="text-right col-form-label">用户名：</label>
                    <div><input type="text" class="form-control" id="name" disabled="" value="{{ $user->name }}"></div>
                </div>
                <div class="form-group">
                    <label for="email" class="text-right col-form-label">邮箱：</label>
                    <div><input type="text" class="form-control" id="email" name="email" required="" placeholder="请输入邮箱" value="{{ $user->email }}"></div>
                </div>
                <div class="form-group">
                    <label for="oldpassword" class="text-right col-form-label">旧密码：</label>
                    <div><input type="password" class="form-control" name="oldpassword" id="oldpassword" placeholder="请输入密码" value=""></div>
                </div>
                <div class="form-group">
                    <label for="password" class="text-right col-form-label">新密码：</label>
                    <div><input type="password" class="form-control" name="password" id="password" placeholder="请输入新密码" value=""></div>
                </div>
                <div class="form-group">
                    <label for="repassword" class="text-right col-form-label">再次输入密码：</label>
                    <div><input type="password" class="form-control" name="repassword" id="repassword" placeholder="再次输入密码" value=""></div>
                </div>
                <div class="form-group mt-2">
                    <small class="text-secondary">如不需要修改密码无需填写新密码项。</small>
                </div>
                <div class="form-group mt-4 d-grid gap-2 col-6 mx-auto">
                    <button type="submit" class="btn btn-primary">确认修改</button>
                </div>
            </form>
        </div>
    </div>
</div>
@endsection
